package data.join.com.database;

import android.content.Context;
import android.database.sqlite.SQLiteDatabase;

import com.github.yuweiguocn.library.greendao.MigrationHelper;

import org.greenrobot.greendao.database.Database;

import data.join.com.database.bean.CommandBeanDao;
import data.join.com.database.bean.DaoMaster;
import data.join.com.database.bean.FileNameSync;
import data.join.com.database.bean.FileNameSyncDao;
import data.join.com.database.bean.FileUploadDao;
import data.join.com.database.bean.PhotoBeanDao;
import data.join.com.database.bean.UpdateBeanDao;
import data.join.com.database.bean.VideoBean;
import data.join.com.database.bean.VideoBeanDao;
import data.join.com.utils.MyLog;


/**
 * Created by Administrator on 2017/6/19.
 */

public class MySQLiteOpenHelper extends DaoMaster.OpenHelper {

    public MySQLiteOpenHelper(Context context, String name, SQLiteDatabase.CursorFactory factory) {
        super(context, name, factory);
    }

    @Override
    public void onUpgrade(Database db, int oldVersion, int newVersion) {
        MigrationHelper.migrate(db, CommandBeanDao.class,PhotoBeanDao.class);
        MyLog.D("MySQLiteOpenHelper onUpgrade");
    }
}
